<?php
//    include("conn.php");
$hostname_conn = "localhost";
$database_conn = "xdq";
$username_conn = "root";//没改的话一般时root
$password_conn = "123456";
//连接MYSQL数据库
$conn = mysqli_connect($hostname_conn, $username_conn, $password_conn,$database_conn)or trigger_error(mysqli_error(),E_USER_ERROR);
mysqli_query($conn,"set names 'utf8mb4'");

    $lessonId=$_POST["id"];
    $sql= "update lessonKey set state='false' where lessonid=$lessonId"; 
    mysqli_query($conn, $sql);
//    echo "插入成功";
?>